import axios from '@/request/http'
import { commonOutDTO, pageCommonInputDTO, pageCommonOutDTO } from '@/api/common.d'
import {
  SsdaListQueryParam,
  SsdaListQueryResult,
  SpdaListQueryParam,
  SpdaListQueryResult,
  SsdawsQueryParam,
  SsdawsQueryResult,
} from './dacx-dto'

export default class dacxService {
  /**
   * 获取诉讼档案列表
   */
  static querySsdaList(
    data: pageCommonInputDTO<SsdaListQueryParam | SpdaListQueryParam>,
  ): Promise<commonOutDTO<pageCommonOutDTO<SsdaListQueryResult[]>>> {
    return axios.post('/api/jygl/querySsdaList', data)
  }

  /**
   * 获取视频档案列表
   */
  static querySpdaList(
    data: pageCommonInputDTO<SsdaListQueryParam | SpdaListQueryParam>,
  ): Promise<commonOutDTO<pageCommonOutDTO<SpdaListQueryResult[]>>> {
    return axios.post('/api/jygl/querySpdaList', data)
  }

  /**
   * 获取归档案卷文书
   */
  static getSsdaws(data: SsdawsQueryParam): Promise<commonOutDTO<SsdawsQueryResult[]>> {
    return axios.post('/api/jygl/getSsdaws', data)
  }

  /**
   * 获取归档情况列表
   */
  static queryGdqklb(
    data: pageCommonInputDTO<any>,
  ): Promise<commonOutDTO<pageCommonOutDTO<any[]>>> {
    return axios.post('/api/gdgl/queryGdqklb', data)
  }

  /**
   * 获取归档制作量
   */
  static queryGdzzl(data: any): Promise<commonOutDTO<any[]>> {
    return axios.post('/api/gdgl/queryGdzzl', data)
  }
  /**
   * 获取归档结果统计详情
   */
  static queryGdJgtjxq(data: any): Promise<commonOutDTO<any[]>> {
    return axios.post('/api/gdgl/queryJgtjxq', data)
  }

  /**
   * 获取借阅情况
   */
  static queryJyqk(data: any): Promise<commonOutDTO<any[]>> {
    return axios.post('/api/jygl/queryJyqk', data)
  }
  /**
   * 获取借阅详情
   */
  static queryJyxq(data: any): Promise<commonOutDTO<any[]>> {
    return axios.post('/api/jygl/queryJyxq', data)
  }
}
